/**
 * Model package.
 */
package fr.umlv.m2.ig.model;

/**
 * This class defines the couple of strings 
 * that represent origin and destination for a train.
 * 
 * @author Gambouele Bertrand.
 * @author Viravout Alexandre.
 */
public class Journey {

	/**
	 * The start station of the journey.
	 */
	private final String origin;

	/**
	 * The destination of the journey.
	 */
	private final String destination;

	/**
	 * Creates a {@link Journey} object.
	 * This constructor is package visible.
	 * It's used directly by {@link Line} inheriting classes.
	 * 
	 * @param origin the start station of the journey.
	 * @param destination the destination of the journey.
	 */
	Journey(final String origin, final String destination) {
		this.origin = origin;
		this.destination = destination;
	}

	/**
	 * Gets the journey origin.
	 * 
	 * @return the journey origin.
	 */
	public String getOrigin() {
		return this.origin;
	}

	/**
	 * Gets the journey destination.
	 * 
	 * @return the destination of the journey.
	 */
	public String getDestination() {
		return this.destination;
	}
}
